A significant portion of the power cost in a 3D pipeline is due to pixel shading. Higher display resolutions and graphics quality, especially in handheld devices, are inconsistent with the need to minimize power dissipation. Running pixel shaders more efficiently would therefore be particularly advantageous.
Coarse pixel shading takes advantage of the fact that geometric occlusion typically introduces higher-frequency details compared to surface shading, and performs shading at a lower rate than visibility testing. Coarse pixel shading is well suited for high pixel density displays, where the effects of reduced shading rates are barely discernible from normal viewing distances. Shading rates may be further reduced in regions of the screen that are blurred or otherwise less perceivable to the user, for instance regions affected by motion or defocus blur, or regions outside the user's foveal vision.
It is difficult to take advantage of these opportunities on current graphics architectures, where shaders execute at per-pixel or per-sample rate. Shading rates may be coarsely controlled by varying frame buffer resolution, but this does not allow more fine grained variation of shading rates, e.g., per object, per triangle, or per image region, which are still coupled to the visibility sampling rate.
Coarse pixel shading (CPS) is an architecture for varying shading rates in a rasterization pipeline, while keeping the visibility sampling rate constant.
Many approaches have been proposed to improve shading efficiency by sampling shading at a lower rate than the visibility sampling rate. Multi-sample anti-aliasing (MSAA) is one such technique, often supported by graphics processor hardware. With MSAA, multiple coverage samples (also called visibility samples) are stored per pixel, but pixel shaders are only executed once for each pixel covered by a primitive. This is in contrast to super-sampling, in which shaders are executed once per covered sample.
Multi-rate shaders are launched at Coarse Pixel (CP) rate and then perform shading at CP, Pixel (P) and Sample (S) rate. Each shading phase involves different inputs at the same rate (e.g. attributes, coverage/execution masks). Since shader execution happens in single instruction multiple data (SIMD) fashion, there is a lot of data that could be shipped with the shader. Since outputs are possible from CP, P and/or S phases of the multi-rate shader, there is information required regarding the states, (x,y)'s etc. required for other data.